<template>
  <div class="layout">
    <!-- 二级路由出口 -->
    <router-view></router-view>
    <!-- tabbar导航栏 -->
    <van-tabbar v-model="active" route placeholder>
      <van-tabbar-item to="/home" icon="home-o">首页</van-tabbar-item>
      <van-tabbar-item to="/qa" icon="chat-o" badge="888">问答</van-tabbar-item>
      <van-tabbar-item to="/movie" icon="video-o" badge="5">视频</van-tabbar-item>
      <van-tabbar-item to="/user" icon="user-o" badge="20">用户</van-tabbar-item>
    </van-tabbar>
  </div>
</template>

<script>
export default {
  name: "layout",
  data(){
      return {
          active:0
      }
  }
};
</script>

<style>
</style>